﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace shenghua.Basics.WebsiteInfos.Dto
{
    public class ContentDto
    {
        public string Picture { get; set; }
        public List<string> Pictures { get; set; }
        public string Description { get; set; }
        public string Content { get; set; }

        public ContentDto()
        {
            Pictures = new List<string>();
        }

        public ContentDto(EasyContent easyContent)
        {
            Picture = easyContent.Picture;
            Pictures = easyContent.Pictures;
            Description = easyContent.Description;
            Content = easyContent.Content;
        }

        public void MapTo(EasyContent easyContent)
        {
            easyContent.Picture = Picture;
            easyContent.Pictures = Pictures;
            easyContent.Description = Description;
            easyContent.Content = Content;
        }
    }
}
